﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Obra.SmugMug.Api
{
    internal static partial class UriTemplates
    {
        internal static class Images
        {
            #region smugmug.images.changeSettings

            private const string ChangeSettingsPreamble = ""
                + "?method=smugmug.images.changeSettings"
                + "&SessionID={sessionId}"
                + "&ImageID={imageId}";

            public const string ChangeAlbum = Images.ChangeSettingsPreamble
                + "&AlbumID={albumId}";

            public const string ChangeCaption = Images.ChangeSettingsPreamble
                + "&Caption={caption}";

            public const string ChangeKeywords = Images.ChangeSettingsPreamble
                + "&Keywords={keywords}";

            public const string ChangeHidden = Images.ChangeSettingsPreamble
                + "&Hidden={hidden}";

            public const string ChangePosition = Images.ChangeSettingsPreamble
                + "&Position={position}";

            #endregion smugmug.images.changeSettings

            public const string Delete = ""
                + "?method=smugmug.images.delete"
                + "&SessionID={sessionId}"
                + "&ImageID={imageId}";

            public const string Get = ""
                + "?method=smugmug.images.get"
                + "&Heavy=1"
                + "&SessionID={sessionId}"
                + "&AlbumID={albumId}";

            public const string GetUrls = ""
                + "?method=smugmug.images.getURLs"
                + "&SessionID={sessionId}"
                + "&ImageID={imageId}"
                + "&TemplateID={templateId}";

            public const string GetInfo = ""
                + "?method=smugmug.images.getInfo"
                + "&SessionID={sessionId}"
                + "&ImageID={imageId}";

            public const string GetExif = ""
                + "?method=smugmug.images.getEXIF"
                + "&SessionID={sessionId}"
                + "&ImageID={imageId}";

            //public const string Upload = "";

            public const string UploadFromUrl = ""
                + "?method=smugmug.images.uploadFromUrl"
                + "&SessionID={sessionId}"
                + "&AlbumID={albumId}"
                + "&Caption={caption}"
                + "&URL={url}"
                // these parameters are optional
                + "&Keywords={keywords}"
                + "&Latitude={latitude}"
                + "&Longitude={longitude}"
                + "&Altitude={altitude}"
                + "&ByteCount={byteCount}"
                + "&MD5Sum={md5Sum}";
        }
    }
}
